<template>
  <div class="personal">
    <van-nav-bar placeholder>
      <template #right>
        <img
          style="width: 24px; height: 24px"
          src="@/assets/images/iconsz.png"
        />
      </template>
    </van-nav-bar>
    <div class="personal__content">
      <div class="personal__header">
        <div class="personal__header-left">
          <img class="avatar" src="@/assets/images/login.png" />
          <div class="personal__header-ns">
            <span>网络多少</span>
            <div>
                <img src="@/assets/images/djtp.png" /> L2等级</div>
          </div>
        </div>
        <div class="personal__header-right">
          <div>
            <img src="@/assets/images/qdjb.png" />
            <span>签到记录</span>
          </div>
        </div>
      </div>

      <div class="personal__info">
        <div class="personal__item">
          <span>722</span>
          <div>学分</div>
        </div>
        <div class="personal__item">
          <span>659</span>
          <div>金币</div>
        </div>
        <div class="personal__item">
          <span>
            <img src="@/assets/images/jl.png" />
          </span>
          <div>考试</div>
        </div>
        <div class="personal__item">
          <span>
            <img src="@/assets/images/sc.png" />
          </span>
          <div>收藏</div>
        </div>
      </div>

      <div class="personal__msg">
        <div class="personal__msg-header">
          <span>我的任务</span>
          <van-icon name="arrow" />
        </div>
        <div class="personal__msg-jm">
          <div class="card" v-for="i in 5" :key="i">
            <img src="@/assets/images/login.png" />
            <span>课程名称课程名称课程</span>
          </div>
        </div>
      </div>

      <div class="personal__group">
        <van-cell-group >
          <van-cell title="每日任务" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/dgrw.png" />
            </template>
          </van-cell>
          <van-cell title="已学课程" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/dgrw.png" />
            </template>
          </van-cell>
          <van-cell title="我的简报" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/wdjb.png" />
            </template>
          </van-cell>
          <van-cell title="我的证书" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/wdgz.png" />
            </template>
          </van-cell>
          <van-cell title="我的兴趣" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/wdxq.png" />
            </template>
          </van-cell>
          <van-cell title="我的社区" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/wdjb.png" />
            </template>
          </van-cell>
          <van-cell title="我的带教" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/wdhf.png" />
            </template>
          </van-cell>
        </van-cell-group>
      </div>

      <div class="personal__group">
        <van-cell-group >
          <van-cell title="帮助中心" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/bzzx.png" />
            </template>
          </van-cell>
          <van-cell title="信息收集" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/xxsj.png" />
            </template>
          </van-cell>
          <van-cell title="检查记录" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/jcjl.png" />
            </template>
          </van-cell>
          <van-cell title="意见反馈" is-link>
            <template #icon>
                <img class="icon" src="@/assets/images/yjfk.png" />
            </template>
          </van-cell>

        </van-cell-group>
      </div>
    </div>
  </div>
</template>
<script name="Personal" setup></script>
<style lang="scss" scoped>
.personal {
  box-sizing: border-box;
  background: linear-gradient(180deg, #cbfff6 0%, #f4f8ff 375px, #f4f8ff 100%);

  ::v-deep .van-nav-bar {
    background-color: transparent;
  }
  &__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    &-left {
      flex: 1;
      display: flex;
      align-items: center;
      .avatar {
        width: 48px;
        height: 48px;
        border-radius: 50%;
        border: 2px solid #fff;
        box-sizing: border-box;
      }
    }
    &-ns {
      padding-left: 8px;
      span {
        font-size: 20px;
        font-family: PingFangSC, PingFang SC;
        font-weight: 500;
        color: #171a1d;
        line-height: 28px;
      }
      div {
        position: relative;
        margin-top: 6px;
        display: flex;
        align-items: center;
        border-radius: 12px;
        background: #ffe88b;
        font-size: 10px;
        font-family: MicrosoftYaHei;
        color: #6c6c6c;
        height: 16px;
        box-sizing: border-box;
        width: 64px;
        justify-content: flex-end;
        padding-right: 10px;
        img{
            position: absolute;
            top: -6px;
            left: -4px;
            width: 24px;
            height: 25px;
        }
      }
    }
    &-right {
      div {
        display: flex;
        align-items: center;
        padding: 8px 10px;
        background: rgba(255, 255, 255, 0.4);
        border-radius: 15px;
        font-size: 10px;
        font-family: PingFangSC, PingFang SC;
        font-weight: 400;
        color: #b79368;
        line-height: 14px;
        img{
            width: 18px;
            height: 18px;
        }
      }
    }
  }
  &__content {
    padding: 4px 18px;
  }

  &__info {
    display: flex;
    align-items: center;
    padding-top: 24px;
    padding-bottom: 20px;
  }
  &__item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    span {
      font-size: 18px;
      font-family: PingFangSC, PingFang SC;
      font-weight: 500;
      color: #272b2d;
      line-height: 25px;
    }
    div {
      padding-top: 4px;
      font-size: 12px;
      font-family: MicrosoftYaHei;
      color: #676b6b;
      line-height: 16px;
    }
    img {
      width: 22px;
      height: 22px;
    }
  }
  &__msg {
    padding: 16px 12px;
    background-color: #fff;
    border-radius: 12px;
    &-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
    }
    &-jm {
      display: flex;
      align-items: center;
      padding-top: 10px;
      overflow-x: auto;
      .card {
        margin-right: 10px;
        span {
          font-size: 12px;
          font-family: PingFangSC, PingFang SC;
          font-weight: 400;
          color: #171a1d;
          line-height: 17px;
          padding-top: 6px;
        }
      }
      img {
        width: 125px;
        height: 71px;
        border-radius: 5px;
      }
    }
  }
  &__group {
    border-radius: 12px;
    overflow: hidden;
    margin-top: 12px;
    .icon {
      transform: translateY(3px);
      width: 18px;
      height: 18px;
      margin-right: 6px;
    }
  }
}
</style>